from flask_wtf import FlaskForm
from wtforms import StringField, TextAreaField
from wtforms.validators import DataRequired, Length

class CourseForm(FlaskForm):
    title = StringField('课程标题', validators=[DataRequired(), Length(min=2, max=128)])
    description = TextAreaField('课程简介', validators=[DataRequired()])
    content = TextAreaField('课程内容', validators=[DataRequired()]) 